package com.gipson.amc.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.gipson.amc.entity.PageByDataTable;
import com.gipson.amc.entity.Role;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 角色 Mapper 接口
 * </p>
 *
 * @author xsyuan
 * @since 2020-03-27
 */
public interface RoleMapper extends BaseMapper<Role> {

    List<Role> getRolesByUsername(@Param("username")String username);

    IPage<Role> queryPageData(Page page,@Param("role")Role role, @Param("pageByDataTable")PageByDataTable pageByDataTable);

    void deleteUserRoleByRoleId(Map<String, Object> map);

}
